function getLength(arg) {
  return arg.length;
}

// 调用函数
console.log(getLength("aaaa"));
console.log(getLength(["abc", "cba", "nba"]));

// 错误调用
console.log(getLength(123));
console.log(getLength());
